<?php

declare (strict_types=1);

namespace app\admin\controller\cloud;

use think\response\Json;
use app\admin\controller\Controller;
use app\admin\service\cloud\Authorize as AuthorizeService;
use cores\exception\BaseException;

/**
 * 授权信息
 * Class Authorize
 * @package app\admin\controller
 */
class Authorize extends Controller
{
    /**
     * 获取授权用户信息
     * @return Json
     * @throws BaseException
     */
    public function info(): Json
    {
        $service = new AuthorizeService;
        $authorize = $service->getInfo();
        return $this->renderSuccess(compact('authorize'));
    }
}
